package com.eureka.feign.controller;

import com.eureka.feign.service.UserClient;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created by liuaiguo on 2017/1/5.
 */
@RestController
public class UserController {

    @Autowired
    private UserClient userClient;

    @RequestMapping(value = "getName",method = RequestMethod.GET)
    public String getName(){
        return userClient.getName("name");
    }
}
